//返回时间戳
const getTimestamp = function (time) {
  time = (new Date(time)).getTime();
  return time;
}

//其他格式时间显示
const filterTimeHMS = function (val) {
  if (val == null || val == '' || val == 0) {
    return "--";
  }
  val = Number(val);
  return (new Date(val)).Format("yyyy-MM-dd hh:mm:ss")
}

const filterTime = function (val) {
  if (val == null || val == '' || val == 0) {
    return "--";
  }
  val = Number(val);
  return (new Date(val)).Format('yyyy-MM-dd')
}


export {
  getTimestamp,
  filterTime,
  filterTimeHMS
}
